import dayjs from 'dayjs'
import relativeTime from 'dayjs/plugin/relativeTime'
import 'dayjs/locale/zh-cn'
// console.log(dayjs('1996-06-01').fromNow())
import Vue from 'vue'
dayjs.locale('zh-cn')
dayjs.extend(relativeTime)
// 时间过滤器
Vue.filter('relativeTime', function (value) {
  return dayjs(value).fromNow()
})
